/* eslint-disable */
/**
 * 弹窗组件
 * 公共导入模板 AddFile
 */
import AddFile from './add-file'

/**
 * 批量引入所有弹窗自定义组件
 */
const batchImport = (() => {
  const requireContext = require.context(
    '@/views/',
    true,
    /\/[^/]+\/PopItems\/index\.js$/
  )

  let popItems = {}
  requireContext.keys().forEach((key) => {
    const path = key.replace('./', '')
    const folderPath = path.split('/').slice(0, -2).join('/')
    // const folderName = folderPath.replace(/\//g, '_')
    const items = require('@/views/' + path).default
    popItems = {
      ...popItems,
      ...items
    }
  })
  return popItems
})()


export default {
  AddFile,
  ...batchImport
}
